home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1997 January: Mac OS SDK / Dev.CD Jan 97 SDK2.toast / Development Kits (Disc 2) / OpenDoc Development Framework / ODF-Interest Archive / July 96 / Re Static Menus.1 < prev    next >
Encoding:
Internet Message Format  |  1996-07-10  |  1.4 KB  |  [TEXT/ttxt]

  1. Subject:     Re: Static Menus
  2. Sent:        7/10/96 3:31 PM
  3. Received:    7/10/96 2:41 PM
  4. From:        Paul Mylchreest, paulm@teamsoft.com
  5. Reply-To:    ODF Interest, ODF-Interest@CILabs.ORG
  6. To:          OpenDoc Development Framework Discussion List, ODF-Interest@CILabs.
  7.  
  8. >Is there any way to "lock down" the root part's menus in such a way that
  9. >the "active" part's menus are either not shown or appended to the root
  10. >part's menus.
  11. >
  12. >Or ... What is the best way to create a part that cannot be activated by
  13. >the user (like simple control parts).
  14. >
  15. >
  16. >========================================================================
  17. >John Casey                         email: jcasey@ncs-ssc.com
  18. >Vice President                     web:   http://www.ncs-ssc.com
  19. >Nation Computer Services           voice: (804) 378-8917
  20. >                                   fax:   (601) 689-8130
  21. >========================================================================
  22.  
  23. I don't know if this is what you want, but looking a ODFButton part's method
  24.  
  25. FW_Boolean COptionBehavior::DoMouseDown(Environment* ev, const
  26. FW_CMouseEvent& theMouseEvent)
  27. {
  28.   FW_Boolean optionPressed = theMouseEvent.IsCopyModifier(ev);
  29.     
  30.   // Switches focus set on the fly to allow selection of the button when it's an
  31.   // embedded frame.
  32.      fFrame->SetFocusSet(ev, optionPressed);  <-- remove this line
  33.  
  34.     return optionPressed;
  35. }
  36.  
  37. Now, the button part menu does not activate.
  38.  
  39. Paul.
  40.  
  41.  
  42.